package org.jim.server.processor.group;

import org.jim.core.ImChannelContext;
import org.jim.core.packets.*;
import org.jim.server.processor.SingleProtocolCmdProcessor;
import org.jim.server.req.ImGroupReq;

import java.util.List;

/**
 * @author ensheng
 */
public interface GroupCmdProcessor extends SingleProtocolCmdProcessor {
    /**
     * 加入群组处理
     */
    JoinGroupRespBody join(Group joinGroup, ImChannelContext imChannelContext);

    /**
     * 获取取群组下所有成员
     */

    List<User> getUserListByGroup(UserListBody userListBody,ImChannelContext imChannelContext);

    /**
     * 错误回调函数
     */
    void onFailed(ImChannelContext imChannelContext,GroupCmdProcessor groupCmdProcessor, UserListBody userListBody);

    /**
     * 创建群组
     */
    void createGroup(RespBody respBody, ImGroupReq imGroupReq,ImChannelContext imChannelContext);

}
